home *** CD-ROM | disk | FTP | other *** search
- var FlashVDSend = {
-
- init : function()
- {
- document.getElementById('sending_url').value=window.arguments[0];
- },
-
- send_url : function()
- {
- document.getElementById('sender_but').disabled=true;
- document.getElementById('after_lbox').style.visibility="visible";
- var httpRequest=false;
- if (window.XMLHttpRequest){
- httpRequest = new XMLHttpRequest();
- if (httpRequest.overrideMimeType) {
- httpRequest.overrideMimeType('text/xml');
- }
- }
- if(!httpRequest){
- document.getElementById('sending_url').style.color="red";
- document.getElementById('loading_image').style.visibility="hidden";
- document.getElementById('after_loading_text').value="Some troubles.";
- return false;
- }
-
- httpRequest.open("POST","http://www.flashvideodownloader.org/feedback/add_service.php");
- httpRequest.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
- httpRequest.onreadystatechange=function(){
- if (httpRequest.readyState == 4){
- if(httpRequest.status == 200){
- document.getElementById('sending_url').style.color="green";
- document.getElementById('loading_image').style.visibility="hidden";
- document.getElementById('after_loading_text').value="Thank you.";
- }else{
- document.getElementById('sending_url').style.color="red";
- document.getElementById('loading_image').style.visibility="hidden";
- document.getElementById('after_loading_text').value="Some troubles.";
- }
- }
- };
- httpRequest.send("adr="+window.arguments[0]);
-
- // var bro=window.opener.getBrowser();
- // var tab=bro.addTab('http://www.flashvideodownloader.org/'+window.arguments[0]);
- // bro.selectedTab = tab;
-
- return true;
- }
-
- }